<?php
namespace app\admin\controller;

use think\Controller;
use think\Cache;
use think\Request;
use think\Db;
use think\Cookie;
use think\Session;

class Index extends Controller
{

    public function index()
    {
        if(Session::get('username') or Cookie::get('username')){
            return view('index');
        } else {
            $this->redirect('/admin/login.html');
        }
    }


}